package team.scau.laboratory_repair;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.Bean;
import team.scau.laboratory_repair.common.utils.spring.SpringContextHolder;

@SpringBootApplication(exclude = {
        org.springframework.boot.autoconfigure.security.servlet.SecurityAutoConfiguration.class
        ,org.springframework.boot.autoconfigure.security.servlet.SecurityFilterAutoConfiguration.class
//        ,org.springframework.boot.autoconfigure.security.servlet.UserDetailsServiceAutoConfiguration.class
})
public class LaboratoryRepairApplication {
    public static void main(String[] args) {
        SpringApplication.run(LaboratoryRepairApplication.class, args);
    }

    @Bean(destroyMethod = "destroy")
    public SpringContextHolder springContextHolder(){
        return new SpringContextHolder();
    }
}
